package com.twu.biblioteca;

/**
 * Created with IntelliJ IDEA.
 * User: Richard
 * Date: 28/01/13
 * Time: 02:28
 * To change this template use File | Settings | File Templates.
 */
public class Book {
    public Book(String _title, boolean _available) {
        title = _title;
        available = _available;
    }

    public String title;
    public boolean available;

    public void reserve(InOut inOut) {
        if (this.available) {
            this.available = false;
            inOut.println("Thank you! Enjoy the book.");
        }
        else {
            inOut.println("Sorry, we don't have that book yet.");
        }
    }
}
